from django.db import models

from myuser.models import MyUser
from prj005.models.info import Info
from prj005.models.models import CreateTimeModel


class Relevant(CreateTimeModel):
    owner = models.ForeignKey(MyUser, on_delete=models.CASCADE, related_name='prj005_relevant')

    info = models.OneToOneField(Info, on_delete=models.CASCADE, related_name='relevant')

    gynaecology_wai_normal = models.BooleanField(blank=True, null=True, verbose_name='外阴-正常', help_text='外阴-正常')

    gynaecology_wai_abnormal = models.BooleanField(blank=True, null=True, verbose_name='外阴-异常', help_text='外阴-异常')

    gynaecology_wai_abnormal_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='外阴-异常-其他', help_text='外阴-异常-其他')

    gynaecology_yin_normal = models.BooleanField(blank=True, null=True, verbose_name='阴道-正常', help_text='阴道-正常')

    # gynaecology_yin_abnormal = models.BooleanField(blank=True, null=True, verbose_name='阴道-异常', help_text='阴道-异常')

    gynaecology_yin_abnormal_chong = models.BooleanField(blank=True, null=True, verbose_name='阴道-粘膜充血', help_text='阴道-粘膜充血')

    gynaecology_yin_abnormal_nong = models.BooleanField(blank=True, null=True, verbose_name='阴道-分泌物增多', help_text='阴道-分泌物增多')

    gynaecology_yin_abnormal_nong_huang = models.BooleanField(blank=True, null=True, verbose_name='阴道-分泌物增多-黄色', help_text='阴道-分泌物增多-黄色')

    gynaecology_yin_abnormal_nong_hui = models.BooleanField(blank=True, null=True, verbose_name='阴道-分泌物增多-灰白色', help_text='阴道-分泌物增多-灰白色')

    gynaecology_yin_abnormal_nong_nong = models.BooleanField(blank=True, null=True, verbose_name='阴道-分泌物增多-脓性', help_text='阴道-分泌物增多-脓性')

    gynaecology_yin_abnormal_nong_xue = models.BooleanField(blank=True, null=True, verbose_name='阴道-分泌物增多-血性', help_text='阴道-分泌物增多-血性')

    gynaecology_yin_abnormal_nong_nx = models.BooleanField(blank=True, null=True, verbose_name='阴道-分泌物增多-脓血相间', help_text='阴道-分泌物增多-脓血相间')

    gynaecology_yin_abnormal_hou = models.BooleanField(blank=True, null=True, verbose_name='阴道-后穹隆饱满触痛', help_text='阴道-异常-后穹隆饱满触痛')

    gynaecology_yin_abnormal_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='阴道-其他', help_text='阴道-其他')

    gynaecology_gong_normal = models.BooleanField(blank=True, null=True, verbose_name='宫颈-正常', help_text='宫颈-正常')

    gynaecology_gong_abnormal = models.BooleanField(blank=True, null=True, verbose_name='宫颈-异常', help_text='宫颈-异常')

    gynaecology_gong_abnormal_xue = models.BooleanField(blank=True, null=True, verbose_name='宫颈-异常-充血', help_text='宫颈-异常-充血')

    gynaecology_gong_abnormal_shui = models.BooleanField(blank=True, null=True, verbose_name='宫颈-异常-水肿', help_text='宫颈-异常-水肿')

    gynaecology_gong_abnormal_mi = models.BooleanField(blank=True, null=True, verbose_name='宫颈-异常-宫颈糜烂样改变', help_text='宫颈-异常-宫颈糜烂样改变')

    MI_LEVEL = (
        ('轻', '轻'),
        ('中', '中'),
        ('重', '重'),
    )
    gynaecology_gong_abnormal_mi_level = models.CharField(max_length=2, choices=MI_LEVEL, blank=True, null=True, verbose_name='宫颈-异常-宫颈糜烂样改变(选择)', help_text='宫颈-异常-宫颈糜烂样改变(选择)')

    gynaecology_gong_abnormal_xi = models.BooleanField(blank=True, null=True, verbose_name='宫颈-异常-宫颈息肉', help_text='宫颈-异常-宫颈息肉')

    gynaecology_gong_abnormal_fei = models.BooleanField(blank=True, null=True, verbose_name='宫颈-异常-宫颈肥大', help_text='宫颈-异常-宫颈肥大')

    gynaecology_gong_abnormal_shui = models.BooleanField(blank=True, null=True, verbose_name='宫颈-异常-水肿', help_text='宫颈-异常-水肿')

    gynaecology_gong_abnormal_ju = models.BooleanField(blank=True, null=True, verbose_name='宫颈-异常-举痛', help_text='宫颈-异常-举痛')

    gynaecology_gong_abnormal_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='宫颈-异常-其他', help_text='宫颈-异常-其他')

    gynaecology_zi_normal = models.BooleanField(blank=True, null=True, verbose_name='子宫体-正常', help_text='子宫体-正常')

    gynaecology_zi_abnormal = models.BooleanField(blank=True, null=True, verbose_name='子宫体-异常', help_text='子宫体-异常')

    gynaecology_zi_abnormal_da = models.BooleanField(blank=True, null=True, verbose_name='子宫体-异常-增大', help_text='子宫体-异常-增大')

    GZAZC = (
        ('40天孕大', '40天孕大'),
        ('50天孕大', '50天孕大'),
        ('60天孕大', '60天孕大'),
        ('90天孕大', '90天孕大')
    )
    gynaecology_zi_abnormal_zeng = models.CharField(max_length=6, choices=GZAZC, blank=True, null=True, verbose_name='子宫体-异常-增大', help_text='子宫体-异常-增大')

    gynaecology_zi_abnormal_ya = models.BooleanField(blank=True, null=True, verbose_name='子宫体-异常-压痛', help_text='子宫体-异常-压痛')

    gynaecology_zi_abnormal_huo = models.BooleanField(blank=True, null=True, verbose_name='子宫体-异常-活动受限', help_text='子宫体-异常-活动受限')

    gynaecology_zi_abnormal_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='子宫体-异常-其他', help_text='子宫体-异常-其他')

    gynaecology_ren_normal = models.BooleanField(blank=True, null=True, verbose_name='骶韧带-正常', help_text='骶韧带-正常')

    gynaecology_ren_abnormal = models.BooleanField(blank=True, null=True, verbose_name='骶韧带-异常', help_text='骶韧带-异常')

    gynaecology_ren_abnormal_zuo = models.BooleanField(blank=True, null=True, verbose_name='骶韧带-异常-左侧增粗/触痛', help_text='骶韧带-异常-左侧增粗/触痛')

    gynaecology_ren_abnormal_you = models.BooleanField(blank=True, null=True, verbose_name='骶韧带-异常-右侧增粗/触痛', help_text='骶韧带-异常-右侧增粗/触痛')

    gynaecology_ren_abnormal_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='骶韧带-异常-其他', help_text='骶韧带-异常-其他')

    gynaecology_zuo_normal = models.BooleanField(blank=True, null=True, verbose_name='左附件-正常', help_text='左附件-正常')

    gynaecology_zuo_abnormal = models.BooleanField(blank=True, null=True, verbose_name='左附件-异常', help_text='左附件-异常')

    gynaecology_zuo_abnormal_pian = models.BooleanField(blank=True, null=True, verbose_name='左附件-异常-片状增厚', help_text='左附件-异常-片状增厚')

    gynaecology_zuo_abnormal_tiao = models.BooleanField(blank=True, null=True, verbose_name='左附件-异常-条索增粗', help_text='左附件-异常-条索增粗')

    gynaecology_zuo_abnormal_bao = models.BooleanField(blank=True, null=True, verbose_name='左附件-异常-包块', help_text='左附件-异常-包块')

    gynaecology_zuo_abnormal_ya = models.BooleanField(blank=True, null=True, verbose_name='左附件-异常-压痛', help_text='左附件-异常-压痛')

    gynaecology_zuo_abnormal_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='左附件-异常-其他', help_text='左附件-异常-其他')

    gynaecology_you_normal = models.BooleanField(blank=True, null=True, verbose_name='右附件-正常', help_text='右附件-正常')

    gynaecology_you_abnormal = models.BooleanField(blank=True, null=True, verbose_name='右附件-异常', help_text='右附件-异常')

    gynaecology_you_abnormal_pian = models.BooleanField(blank=True, null=True, verbose_name='右附件-异常-片状增厚', help_text='右附件-异常-片状增厚')

    gynaecology_you_abnormal_tiao = models.BooleanField(blank=True, null=True, verbose_name='右附件-异常-条索增粗', help_text='右附件-异常-条索增粗')

    gynaecology_you_abnormal_bao = models.BooleanField(blank=True, null=True, verbose_name='右附件-异常-包块', help_text='右附件-异常-包块')

    gynaecology_you_abnormal_ya = models.BooleanField(blank=True, null=True, verbose_name='右附件-异常-压痛', help_text='右附件-异常-压痛')

    gynaecology_you_abnormal_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='右附件-异常-其他', help_text='右附件-异常-其他')

    belly_zc = models.BooleanField(blank=True, null=True, verbose_name='腹部检查-正常', help_text='腹部检查-正常')

    belly_xiaya = models.BooleanField(blank=True, null=True, verbose_name='下腹正中压痛', help_text='下腹正中压痛')

    belly_xiafan = models.BooleanField(blank=True, null=True, verbose_name='下腹正中反跳痛', help_text='下腹正中反跳痛')

    belly_zuoya = models.BooleanField(blank=True, null=True, verbose_name='左下腹压痛', help_text='左下腹压痛')

    belly_zuofan = models.BooleanField(blank=True, null=True, verbose_name='左下腹反跳痛', help_text='左下腹反跳痛')

    belly_youya = models.BooleanField(blank=True, null=True, verbose_name='右下腹压痛', help_text='右下腹压痛')

    belly_youfan = models.BooleanField(blank=True, null=True, verbose_name='右下腹反跳痛', help_text='右下腹反跳痛')

    belly_ji = models.BooleanField(blank=True, null=True, verbose_name='肌紧张', help_text='肌紧张')

    belly_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='腹部检查-其他', help_text='腹部检查-其他')

    hemocyte_no = models.BooleanField(blank=True, null=True, verbose_name='血细胞分析-未查', help_text='血细胞分析-未查')

    hemocyte_yes = models.BooleanField(blank=True, null=True, verbose_name='血细胞分析-已查', help_text='血细胞分析-已查')

    leucocyte_normal = models.BooleanField(blank=True, null=True, verbose_name='白细胞总数-正常', help_text='白细胞总数-正常')

    leucocyte_abnormal = models.BooleanField(blank=True, null=True, verbose_name='白细胞总数-异常', help_text='白细胞总数-异常')

    leucocyte_abnormal_detail = models.CharField(max_length=50, blank=True, null=True, verbose_name='白细胞总数-异常描述', help_text='白细胞总数-异常描述')

    neutrophil_normal = models.BooleanField(blank=True, null=True, verbose_name='中性粒细胞百分比-正常', help_text='中性粒细胞百分比-正常')

    neutrophil_abnormal = models.BooleanField(blank=True, null=True, verbose_name='中性粒细胞百分比-异常', help_text='中性粒细胞百分比-异常')

    neutrophil_abnormal_detail = models.CharField(max_length=50, blank=True, null=True, verbose_name='中性粒细胞百分比-异常描述', help_text='中性粒细胞百分比-异常描述')

    hemocyte_yes_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='血细胞分析-已查-其他', help_text='血细胞分析-已查-其他')

    protein_no = models.BooleanField(blank=True, null=True, verbose_name='全血C反应蛋白-未查', help_text='全血C反应蛋白-未查')

    protein_yes = models.BooleanField(blank=True, null=True, verbose_name='全血C反应蛋白-已查', help_text='全血C反应蛋白-已查')

    protein_yes_normal = models.BooleanField(blank=True, null=True, verbose_name='全血C反应蛋白-已查-正常', help_text='全血C反应蛋白-已查-正常')

    protein_yes_abnormal = models.BooleanField(blank=True, null=True, verbose_name='全血C反应蛋白-已查-异常', help_text='全血C反应蛋白-已查-异常')

    protein_yes_abnormal_detail = models.CharField(max_length=50, blank=True, null=True, verbose_name='全血C反应蛋白-已查-异常描述', help_text='全血C反应蛋白-已查-异常描述')

    erythrocyte_no = models.BooleanField(blank=True, null=True, verbose_name='红细胞沉降率-未查', help_text='红细胞沉降率-未查')

    erythrocyte_yes = models.BooleanField(blank=True, null=True, verbose_name='红细胞沉降率-已查', help_text='红细胞沉降率-已查')

    erythrocyte_yes_normal = models.BooleanField(blank=True, null=True, verbose_name='红细胞沉降率-已查-正常', help_text='红细胞沉降率-已查-正常')

    erythrocyte_yes_abnormal = models.BooleanField(blank=True, null=True, verbose_name='红细胞沉降率-已查-异常', help_text='红细胞沉降率-已查-异常')

    erythrocyte_yes_abnormal_detail = models.CharField(max_length=50, blank=True, null=True, verbose_name='红细胞沉降率-已查-异常描述', help_text='红细胞沉降率-已查-异常描述')

    check_vagina_no = models.BooleanField(blank=True, null=True, verbose_name='阴道分泌物常规检查-未查', help_text='阴道分泌物常规检查-未查')

    check_vagina_yes = models.BooleanField(blank=True, null=True, verbose_name='阴道分泌物常规检查-已查', help_text='阴道分泌物常规检查-已查')

    CHARACTER_CHOICES = (
        ('阴性', '阴性'),
        ('阳性', '阳性')
    )
    check_vagina_qing = models.CharField(max_length=10, blank=True, null=True, verbose_name='清洁度', help_text='清洁度')

    check_vagina_ph = models.CharField(max_length=10, blank=True, null=True, verbose_name='PH值', help_text='PH值')

    check_vagina_xian = models.CharField(max_length=4, choices=CHARACTER_CHOICES, blank=True, null=True, verbose_name='线索细胞', help_text='线索细胞')

    check_vagina_zhen = models.CharField(max_length=4, choices=CHARACTER_CHOICES, blank=True, null=True, verbose_name='真菌', help_text='真菌')

    check_vagina_di = models.CharField(max_length=4, choices=CHARACTER_CHOICES, blank=True, null=True, verbose_name='滴虫', help_text='滴虫')

    check_vagina_bai_bool = models.BooleanField(blank=True, null=True, verbose_name='白细胞计数', help_text='白细胞计数')

    check_vagina_bai = models.IntegerField(blank=True, null=True, verbose_name='白细胞计数-个数', help_text='白细胞计数-个数')

    check_vagina_ru_bool = models.BooleanField(blank=True, null=True, verbose_name='乳杆菌', help_text='乳杆菌')

    check_vagina_ru = models.IntegerField(blank=True, null=True, verbose_name='乳杆菌-个数', help_text='乳杆菌-个数')

    check_vagina_za_bool = models.BooleanField(blank=True, null=True, verbose_name='杂菌', help_text='杂菌')

    check_vagina_za = models.IntegerField(blank=True, null=True, verbose_name='杂菌-个数', help_text='杂菌-个数')

    check_vagina_mei_bool = models.BooleanField(blank=True, null=True, verbose_name='白细胞脂酶', help_text='白细胞脂酶')

    check_vagina_mei = models.IntegerField(blank=True, null=True, verbose_name='白细胞脂酶-个数', help_text='白细胞脂酶-个数')

    check_vagina_tuo_bool = models.BooleanField(blank=True, null=True, verbose_name='唾液酸苷酶', help_text='唾液酸苷酶')

    check_vagina_tuo = models.IntegerField(blank=True, null=True, verbose_name='唾液酸苷酶-个数', help_text='唾液酸苷酶-个数')

    check_vagina_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='其他', help_text='其他')

    check_cervix_no = models.BooleanField(blank=True, null=True, verbose_name='宫颈管分泌物检测-未作', help_text='宫颈管分泌物检测-未作')

    check_cervix_yes = models.BooleanField(blank=True, null=True, verbose_name='宫颈管分泌物检测-已作', help_text='宫颈管分泌物检测-已作')

    check_cervix_lin = models.BooleanField(blank=True, null=True, verbose_name='淋病奈瑟菌', help_text='淋病奈瑟菌')

    check_cervix_lin_type = models.CharField(max_length=4, choices=CHARACTER_CHOICES, blank=True, null=True, verbose_name='淋病奈瑟菌-性状', help_text='淋病奈瑟菌-性状')

    check_cervix_sha = models.BooleanField(blank=True, null=True, verbose_name='沙眼衣原体', help_text='沙眼衣原体')

    check_cervix_sha_type = models.CharField(max_length=4, choices=CHARACTER_CHOICES, blank=True, null=True, verbose_name='沙眼衣原体-性状', help_text='沙眼衣原体-性状')

    check_cervix_jie = models.BooleanField(blank=True, null=True, verbose_name='解脲支原体', help_text='解脲支原体')

    check_cervix_jie_type = models.CharField(max_length=4, choices=CHARACTER_CHOICES, blank=True, null=True, verbose_name='解脲支原体-性状', help_text='解脲支原体-性状')

    check_cervix_ren = models.BooleanField(blank=True, null=True, verbose_name='人型支原体', help_text='人型支原体')

    check_cervix_ren_type = models.CharField(max_length=4, choices=CHARACTER_CHOICES, blank=True, null=True, verbose_name='人型支原体-性状', help_text='人型支原体-性状')

    check_cervix_sheng = models.BooleanField(blank=True, null=True, verbose_name='生殖支原体', help_text='生殖支原体')

    check_cervix_sheng_type = models.CharField(max_length=4, choices=CHARACTER_CHOICES, blank=True, null=True, verbose_name='生殖支原体-性状', help_text='生殖支原体-性状')

    check_cervix_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='宫颈管分泌物检测-其他', help_text='宫颈管分泌物检测-其他')

    check_hpv_no = models.BooleanField(blank=True, null=True, verbose_name='HPV检测-未作', help_text='HPV检测-未作')

    check_hpv_yes = models.BooleanField(blank=True, null=True, verbose_name='HPV检测-已作', help_text='HPV检测-已作')

    check_hpv_character = models.CharField(max_length=4, choices=CHARACTER_CHOICES, blank=True, null=True, verbose_name='HPV检测-性', help_text='HPV检测-性')

    check_hpv_character_yang = models.CharField(max_length=50, blank=True, null=True, verbose_name='HPV检测-阳性详情', help_text='HPV检测-阳性详情')

    check_hc_no = models.BooleanField(blank=True, null=True, verbose_name='人乳头瘤病毒核酸检测杂交二代（HC2）检测-未作', help_text='人乳头瘤病毒核酸检测杂交二代（HC2）检测-未作')

    check_hc_yes = models.BooleanField(blank=True, null=True, verbose_name='人乳头瘤病毒核酸检测杂交二代（HC2）检测-已作', help_text='人乳头瘤病毒核酸检测杂交二代（HC2）检测-已作')

    check_hc_character = models.CharField(max_length=4, choices=CHARACTER_CHOICES, blank=True, null=True, verbose_name='人乳头瘤病毒核酸检测杂交二代-性', help_text='人乳头瘤病毒核酸检测杂交二代-性')

    check_hc_character_yang = models.CharField(max_length=50, blank=True, null=True, verbose_name='人乳头瘤病毒核酸检测杂交二代-阳性详情', help_text='人乳头瘤病毒核酸检测杂交二代-阳性详情')

    # check_hpv_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='HPV检测-其他', help_text='HPV检测-其他')

    check_ultrasound_zuocu = models.BooleanField(blank=True, null=True, verbose_name='左侧输卵管增粗', help_text='左侧输卵管增粗')

    check_ultrasound_youcu = models.BooleanField(blank=True, null=True, verbose_name='右侧输卵管增粗', help_text='右侧输卵管增粗')

    check_ultrasound_zuoji = models.BooleanField(blank=True, null=True, verbose_name='左侧输卵管积液', help_text='左侧输卵管积液')

    check_ultrasound_zuoji_v = models.CharField(max_length=10, blank=True, null=True, verbose_name='左侧输卵管积液cm', help_text='左侧输卵管积液cm')

    check_ultrasound_youji = models.BooleanField(blank=True, null=True, verbose_name='右侧输卵管积液', help_text='右侧输卵管积液')

    check_ultrasound_youji_v = models.CharField(max_length=10, blank=True, null=True, verbose_name='右侧输卵管积液cm', help_text='右侧输卵管积液cm')

    CUBC = (
        ('最大直径<3cm', '最大直径<3cm'),
        ('3cm≤最大直径≤6cm', '3cm≤最大直径≤6cm'),
        ('最大直径>6cm', '最大直径>6cm')
    )
    check_ultrasound_bao = models.CharField(max_length=15, choices=CUBC, blank=True, null=True, verbose_name='盆腔炎性包块-选项', help_text='盆腔炎性包块-选项')

    check_ultrasound_bao_bool = models.BooleanField(blank=True, null=True, verbose_name='盆腔炎性包块', help_text='盆腔炎性包块')

    CUJC = (
        ('深度<2mm', '深度<2mm'),
        ('深度2-3mm', '深度2-3mm'),
        ('深度>3mm', '深度>3mm')
    )
    check_ultrasound_ji = models.CharField(max_length=10, choices=CUJC, blank=True, null=True, verbose_name='盆腔积液-选项', help_text='盆腔积液-选项')

    check_ultrasound_ji_bool = models.BooleanField(blank=True, null=True, verbose_name='盆腔积液', help_text='盆腔积液')

    check_contrast_no = models.BooleanField(blank=True, null=True, verbose_name='子宫输卵管造影-无', help_text='子宫输卵管造影-无')

    check_contrast_yes = models.BooleanField(blank=True, null=True, verbose_name='子宫输卵管造影-有', help_text='子宫输卵管造影-有')

    check_contrast_yes_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='子宫输卵管造影-有(详情)', help_text='子宫输卵管造影-有(详情)')

    # check_contrast_qita = models.CharField(max_length=50, blank=True, null=True, verbose_name='子宫输卵管造影-其他', help_text='子宫输卵管造影-其他')

    check_others_yin = models.BooleanField(blank=True, null=True, verbose_name='阴道后穹隆穿刺', help_text='阴道后穹隆穿刺')
    wu_check_others_yin = models.BooleanField(blank=True, null=True, verbose_name='阴道后穹隆穿刺-无', help_text='阴道后穹隆穿刺-无')

    check_others_yin_detail = models.CharField(max_length=50, blank=True, null=True, verbose_name='阴道后穹隆穿刺-有详情', help_text='阴道后穹隆穿刺-有详情')

    check_others_zi = models.BooleanField(blank=True, null=True, verbose_name='子宫内膜活组织检查', help_text='子宫内膜活组织检查')
    wu_check_others_zi = models.BooleanField(blank=True, null=True, verbose_name='子宫内膜活组织检查-无', help_text='子宫内膜活组织检查-无')

    check_others_zi_detail = models.CharField(max_length=50, blank=True, null=True, verbose_name='子宫内膜活组织检查-有详情', help_text='子宫内膜活组织检查-有详情')

    check_others_fu = models.BooleanField(blank=True, null=True, verbose_name='腹腔镜检查', help_text='腹腔镜检查')
    wu_check_others_fu = models.BooleanField(blank=True, null=True, verbose_name='腹腔镜检查-无', help_text='腹腔镜检查-无')

    check_others_fu_detail = models.CharField(max_length=50, blank=True, null=True, verbose_name='腹腔镜检查-有详情', help_text='腹腔镜检查-有详情')

    check_others_mri = models.BooleanField(blank=True, null=True, verbose_name='MRI检查', help_text='MRI检查')
    wu_check_others_mri = models.BooleanField(blank=True, null=True, verbose_name='MRI检查-无', help_text='MRI检查-无')

    check_others_mri_detail = models.CharField(max_length=50, blank=True, null=True, verbose_name='MRI检查-有详情', help_text='MRI检查-有详情')

    class Meta:
        verbose_name = '相关检查'
        verbose_name_plural = verbose_name
